package com.zoe.vhr.service.impl;

import com.zoe.vhr.mapper.RoleMapper;
import com.zoe.vhr.model.Role;
import com.zoe.vhr.service.RoleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @Author Zoe.Zhang
 * @Date: 2021/08/05
 * @Description
 */
@Service
public class RoleServiceImpl implements RoleService {
    @Autowired
    RoleMapper roleMapper;

    @Override
    public List<Role> listAllRoles() {
        return roleMapper.listAllRoles();
    }

    @Override
    public int saveRole(Role role) {
        return roleMapper.saveRole(role);
    }

    @Override
    public int deleteRole(Integer roleId) {
        return roleMapper.deleteRole(roleId);
    }
}
